function domainOut = SwitchDomain(domainIn)
nDim = size(domainIn,2)/2;
domainOut = domainIn;
for iDim = 1:nDim
    domainOut(iDim*2-1) = domainIn(iDim);
    domainOut(iDim*2) = domainIn(iDim+nDim);
end